<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
        <title></title>
</head>
<style>
body{
    padding:0;
        left:0;
}
    *{
        padding:0;
        left:0;
    }
    .list{
        display: flex;
        margin:0 auto;
        margin-bottom: 20px;
        align-items: center;
    }
    .input input{
        height: 25px;
        border:1px solid #ccc;
        border-radius: 5px;
        padding:0 10px;
    }
    .cont{
        margin:0 auto;
        margin-top: 25px;
        display: grid;
    }
    .btn{
        width: 85%;
        height: 35px;
        text-align: center;
        background:#2643ff;
        color:#fff;
        line-height: 35px;
        margin:10px auto;

    }
    .tupian{
        width: 200px;
        height:200px;
        margin:0 auto;
        display: block;
    }
    .input{
        width: 85%;
        box-sizing: border-box;
        height: 35px;
        padding:0 10px;
        margin:0 auto;
        margin-bottom: 10px;
        border:1px solid #ccc;
    }
    .tipp{
        font-size: 14px;
        color:#666;
        width:85%;
        margin:10px auto;
    }
    .title{
     border-bottom: 1px solid #ccc;
     line-height: 32px;
    font-size: 16px;
    font-weight: bold;
    text-align: center;
    }
</style>
<body>
    <div class="title">
        服务单查验
    </div>
<div class="cont">
    <!--<div class="list">-->
    <!--    <div class="title">车牌号：</div>-->
    <!--    <div class="input"><input type="text" placeholder="请输入车牌号" id="car_num"></div>-->
    <!--</div>-->
    <!--<div class="list">-->
    <!--    <div class="title">车架号：</div>-->
    <!--    <div class="input"><input type="text" placeholder="请输入车架号" id="car_vin"></div>-->
    <!--</div>-->
    <image src="/sou.jpg" class="tupian"></image>
    <input class="input" type="text" placeholder="请输入车牌号码" id="car_num">
    <input class="input" type="text" placeholder="请输入车辆车架号后4位" id="car_vin">
    <div class="btn">进行查验</div>
    <div class="tipp">
        备注：请输入相匹配的车牌号码与车架号，若查验成功，将展示服务单信息，否则，说明该车牌号与车架号不匹配或未查找到相应服务单。
    </div>
</div>
    
</body>
<script src="/assets/libs/jquery/dist/jquery.min.js"></script>
<script>
$(".btn").click(function(){
    var car_num = $("#car_num").val();
    var car_vin = $("#car_vin").val();
    if(car_num==''){
        alert('请填写车牌号码')
        return false
    }
    if(car_vin==''){
        alert('请输入车辆车架号后4位')
        return false
    }
    $.ajax({
        type:"post",
        dataType:'json',
        url:"/index/qianzi3/cha_post",
        data:{car_num:car_num,car_vin:car_vin},
        success:function(data){
            if(data.code == 1){
                // layer.msg(data.msg);
                document.location.href = '/index/qianzi3/cha_t?car_num='+car_num+'&car_vin='+car_vin
                return false;
            }else{
                alert(data.msg);
                return false;
            }
        }
    });
    // document.location.href = 'http://www.cnblogs.com/chenyablog'
})
</script>
</html>